const getTypeName = (type) => {
  switch (type) {
    case 1:
      return "单选";
    case 2:
      return "多选";
    case 3:
      return "判断";
    case 4:
      return "填空";
    case 5:
      return "解答";
    default:
      return "";
  }
};
const getDiffcultLevelName = (level) => {
  //难度等级 1-99简单 100-199中等 200-299较难 300-399困难 400-499超难
  if (level >= 1 && level <= 99) {
    return "简单";
  } else if (level >= 100 && level <= 199) {
    return "中等";
  } else if (level >= 200 && level <= 299) {
    return "较难";
  } else if (level >= 300 && level <= 399) {
    return "困难";
  } else if (level >= 400 && level <= 499) {
    return "超难";
  } else {
    return "无限难度";
  }
};
const getUserTypeName = (type) => {
  switch (type) {
    case 1:
      return "普通用户";
    case 2:
      return "学生";
    case 3:
      return "老师";
    case 4:
      return "管理员";
    default:
      return "未知";
  }
};
const getUserTypeColor = (type) => {
  switch (type) {
    case 1:
      return "#4CAF50";
    case 2:
      return "#2196F3";
    case 3:
      return "#FF9800";
    case 4:
      return "#F44336";
    default:
      return "#9E9E9E";
  }
};
export { getTypeName, getDiffcultLevelName, getUserTypeName, getUserTypeColor };
